<div class="pagination">
    <nav>
        <ul class="pager">
            {% if page.has_previous %}
                <li class="previous">
                    <a href="?page={{ page.previous_page_number }}&query={{ cd.query }}"><span aria-hidden="true">&larr;</span> 上一页</a>
                </li>
            {% endif %}
            {% if page.has_next %}
                <li class="next">
                    <a href="?page={{ page.next_page_number }}&query={{ cd.query }}">下一页 <span aria-hidden="true">&rarr;</span></a>
                </li>
            {% endif %}
        </ul>
    </nav>
</div>